package com.bxd.baodan.fragment;

import android.os.Bundle;
import android.support.annotation.Nullable;
import android.view.View;
import android.widget.TextView;

import com.bxd.baodan.R;
import com.bxd.baodan.activity.PersonalDesignActivity;
import com.bxd.baodan.item.FamDesignBean;
import com.bxd.baodan.logic.DesignStep;

/**
 *
 */

public class BaseStepFragment extends BaseFragment {

    protected String role;
    protected String roleText;
    protected TextView title;
    protected TextView title1;
    protected TextView title2;

    public DesignStep getDesignStep() {
        return ((PersonalDesignActivity) getActivity()).designStep;
    }
    public FamDesignBean getBean() {
        return ((PersonalDesignActivity) getActivity()).famDesignBean;
    }

    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);

    }

    @Override
    public void onViewCreated(View view, @Nullable Bundle savedInstanceState) {
        super.onViewCreated(view, savedInstanceState);
        try {
            title =(TextView)  view.findViewById(R.id.title);
        } catch (Exception e) {
            e.printStackTrace();
        }

        try {
            title1 =(TextView)  view.findViewById(R.id.title1);
        } catch (Exception e) {
            e.printStackTrace();
        }

        try {
            title2 =(TextView)  view.findViewById(R.id.title2);
        } catch (Exception e) {
            e.printStackTrace();
        }

        role = getDesignStep().role;
        roleText = getDesignStep().roleText;
    }
}
